//
//  Subject.h
//  观察者模式
//
//  Created by flannery on 2018/12/19.
//  Copyright © 2018年 flannery. All rights reserved.
//

#import <Foundation/Foundation.h>
@class Observer;

@interface Subject : NSObject
@property (nonatomic, strong) NSMutableArray *observers;
@property (nonatomic, assign) int state;
-(void)attach:(Observer*)observer;
-(void)notifyAllObservers;
@end
